home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1992 …SCII & the Runetime Code / ADC Developer CD (1992-07) (''Butch ASCII And The Runtime Code'')_iso / Dev.CD 199207.iso / Tools & Apps / OS⁄Toolbox / Apple Events / AE Word Services 1.0d6 / Writeswell Jr. Source / headers / ObText.h < prev    next >
Encoding:
Text File  |  1992-04-23  |  2.4 KB  |  82 lines  |  [TEXT/KAHL]

  1. /* ObText.h
  2.  * ©1992 Working Software, Inc.
  3.  * This source code is copyrighted.  Permission is granted to use the Word Services
  4.  * portion of the Writeswell Jr. source code in your own programs, but you 
  5.  * may not distribute the Writeswell Jr. word-processor code as a 
  6.  * commercial product.  If you modify the code, please do not call it 
  7.  * Writeswell Jr. (or Writeswell.)  This will ensure that people understand the 
  8.  * program and don’t have to deal with a number of different versions with 
  9.  * who-knows-what going on in the code.
  10.  * 
  11.  * Writeswell Jr. and Writeswell are trademarks of Working Software, Inc.
  12.  * 26 Dec 91 Mike Crawford
  13.  */
  14.  
  15. enum {
  16.     typePString = 'PStr'        /* Descriptor type for a pascal string */
  17. };
  18.  
  19. enum {
  20.     typeTEText = 'TETx'            /* Text in a TextEdit field */
  21. };
  22.  
  23. typedef struct {
  24.     TEHandle    textH;
  25.     short        startPos;        /* Short cuz TE only handles 32k o' text! */
  26.     short        length;
  27.     DescType    propertyCode;
  28. } TETextTokenBody;
  29.  
  30. OSErr DispatchTEText( AEDesc *tokenPtr,
  31.                         AppleEvent *theAppleEventPtr,
  32.                         AppleEvent *replyEventPtr,
  33.                         long refCon );
  34.  
  35. OSErr TETextGetDataHandler( AEDesc *tokenPtr,
  36.                         AppleEvent *theAppleEventPtr,
  37.                         AppleEvent *replyEventPtr,
  38.                         long refCon );
  39.  
  40. OSErr TETextSetDataHandler( AEDesc *tokenPtr,
  41.                         AppleEvent *theAppleEventPtr,
  42.                         AppleEvent *replyEventPtr,
  43.                         long refCon );
  44.  
  45. pascal OSErr TextFromWind(DescType desiredClass,
  46.                             const AEDesc *container,
  47.                             DescType containerClass,
  48.                             DescType form,
  49.                             const AEDesc *selectionData,
  50.                             AEDesc *theToken,
  51.                             long LongInt);
  52.  
  53. pascal OSErr WordFromTEText(DescType desiredClass,
  54.                             const AEDesc *container,
  55.                             DescType containerClass,
  56.                             DescType form,
  57.                             const AEDesc *selectionData,
  58.                             AEDesc *theToken,
  59.                             long LongInt);
  60.  
  61. pascal OSErr CharFromTEText(DescType desiredClass,
  62.                             const AEDesc *container,
  63.                             DescType containerClass,
  64.                             DescType form,
  65.                             const AEDesc *selectionData,
  66.                             AEDesc *theToken,
  67.                             long LongInt);
  68.  
  69. pascal OSErr PropFromTEText(DescType desiredClass,
  70.                             const AEDesc *container,
  71.                             DescType containerClass,
  72.                             DescType form,
  73.                             const AEDesc *selectionData,
  74.                             AEDesc *theToken,
  75.                             long LongInt);
  76.  
  77. pascal OSErr TextPtrToPString( DescType typeCode,
  78.                                 Ptr dataPtr,
  79.                                 Size dataSize,
  80.                                 DescType toType,
  81.                                 long handlerRefCon,
  82.                                 AEDesc *resultPtr );